l1 = [13, 545, 1231, 44]
l2 = [13, 545, 1231, 455, 999, 66]
l3 = []

def test():
    for i in l1:
        try:
            l2.index(i)
            l3.append(i)
        except:
            continue
    print(l3)

if __name__ == '__main__':
    test()
